package com.shop.user.api.api;

import com.shop.common.model.param.user.MessageInput;
import com.shop.common.util.excption.UserNotFoundException;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import javax.servlet.http.HttpServletRequest;

/**
 * @Description:
 *
 * @author zhoulk
 * @date: 2019年05月09日  0:45
 */
@RequestMapping("/user")
public interface IMessageApi {

    /**
     * @Function com.shop.user.api.api.IMessageApi.qryMessaes
     * @Description // 查询消息列表
     *
     * @param: messageInput
     * @return java.lang.String
     * @errorCode //
     *
     * @Author zhoulk
     * @Date 2019/5/9 0:45
     *
     **/
    @GetMapping("/messages")
    String qryMessaes(MessageInput messageInput,Integer index, Integer pageSize, HttpServletRequest request) throws UserNotFoundException;

    /**
     * @Function com.shop.user.api.api.IMessageApi.modMessageState
     * @Description // 修改消息状态
     *
     * @param: MessageId
     * @param: state
     * @return java.lang.String
     * @errorCode //
     *
     * @Author zhoulk
     * @Date 2019/5/9 0:47
     *
     **/
    @GetMapping("/redMessage")
    String redMessage(Integer messageId,  HttpServletRequest request) throws UserNotFoundException;

    @DeleteMapping("/message")
    String delMessage(Integer messageId, HttpServletRequest request) throws UserNotFoundException;

}
